package com.bdqn.hospital.mapper;

import com.bdqn.hospital.pojo.Department;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * @version : 1.0
 * @Author :guogd
 * @createTime: 2023/03/01 14:29
 * @Description: com.bdqn.hospital.mapper
 */
@Mapper
public interface DepartmentMapper {
    /**
     * 查询所有就诊科室信息
     * @return
     */
    @Select("select * from department")
    List<Department> findAll();
    //获取所有科室信息
    @Select("select * from department")
    List<Department> getDepartmentAll();

    /**
     * 根据id获取就诊科室信息
     * @param id
     * @return
     */
    @Select("select * from department where id=#{id}")
    Department getById(Integer id);
}
